home *** CD-ROM | disk | FTP | other *** search
/ C/C++ Users Group Library 1996 July / C-C++ Users Group Library July 1996.iso / vol_400 / 423_01 / recio200 / usage.txt < prev    next >
Encoding:
Text File  |  1994-04-15  |  22.5 KB  |  653 lines

  1.     Title: STANDARD USAGE OF C LANGUAGE RECIO LIBRARY
  2. Copyright: (C) 1994 William Pierpoint
  3.   Version: 2.00
  4.      Date: April 15, 1994
  5.  
  6.  
  7.  
  8. 1.0 INTRODUCTION
  9.  
  10. The implementation descibed by this standard usage is a superset of the
  11. recio specification.  Enhancements are noted in the text.
  12.  
  13.  
  14. 1.1 Mnemonics
  15.  
  16. The recio functions have been given a consistent mnemonic naming
  17. convention.  All recio functions are in lower case and start with
  18. the letter r.  Function names are analogous to <stdio.h> functions.
  19. Mnemonics are as follows:
  20.  
  21. Single letter (field functions)               Multi-letter
  22. ----------------------------------------      -----------------
  23. b - base (prefix)                             beg - beginning
  24. c - column (prefix), character (suffix)       ch  - character
  25. d - double (suffix)                           col - column         
  26. f - float (suffix)                            cxt - context        
  27. i - integer (suffix)                          eof - end of file
  28. l - long (suffix)                             err - error          
  29. n - number                                    fld - field buffer
  30. r - record pointer (first letter)             fn  - function
  31. s - string pointer (suffix)                   no  - number         
  32. u - unsigned (suffix)                           rec - record buffer  
  33.                           siz - size of buffer
  34.                           str - string
  35.                           txt - text
  36. 1.2 Order
  37.  
  38. The order in which the prefix mnemonics appear indicates the order in which
  39. the arguments appear in the function.  The suffix mnemonics of the input 
  40. functions tell you what the function returns.  The suffix mnemonics of the 
  41. output functions indicate the last argument and tell you what the function 
  42. outputs.  All output functions return an integer with a zero value if the 
  43. function executed successfully.
  44.  
  45. For example, the input function rbgetui():
  46.  
  47.     arguments:  r - record pointer
  48.                 b - base (radix) of input
  49.       returns: ui - unsigned integer
  50.  
  51. The output function rbputui():
  52.  
  53.     arguments:  r - record pointer
  54.                 b - base (radix) of input
  55.                ui - unsigned integer is output
  56.  
  57. Note: c is used in the prefix of a function's name only once even if there are 
  58.       two column arguments.  If the function inputs or outputs a character, 
  59.       there is only one column argument; otherwise there are two.
  60.  
  61.  
  62.  
  63. 2.0 ERROR AND WARNING CHECKING
  64.  
  65. The functions declared in the header <recio.h> make use of the errno macro
  66. defined in section 4.1.3 of ANSI X3.159-1989.  This mechanism was chosen
  67. because (1) the <stdlib.h> conversion functions (strtod(), strtol(), etc.)
  68. make use of this error reporting mechanism and (2) the <recio.h> functions
  69. make use of the <stdlib.h> conversion functions.
  70.  
  71. In this implementation, errno can return the following macro constants:
  72.  
  73.          0 - No error.
  74.     EACCES - permission denied.
  75.     EINVAL - invalid argument (usually null record pointer).
  76.     EMFILE - too many open files.
  77.     ENOENT - no such file or directory.
  78.     ENOMEM - out of memory.
  79.  
  80. Beginning with version 1.1, recio functions set errno when the record 
  81. pointer is invalid and set an internal error number when the record pointer 
  82. is valid.  The recio error number is accessed through the rerror function.
  83.  
  84. The rerror function can return the following macro constants:
  85.  
  86.          0 - No error.
  87.   R_EINVAL - invalid argument (not the record pointer).
  88.  R_EINVDAT - invalid data.
  89.  R_EINVMOD - invalid mode.
  90.  R_EMISDAT - missing data.
  91.   R_ENOMEM - out of memory.
  92.   R_ENOPUT - unable to write data to output.
  93.   R_ERANGE - data out of range.
  94.  
  95. Beginning with version 2.0, recio functions set an internal warning number 
  96. when the record pointer is valid.  The recio library never sets the warning 
  97. number when the record pointer is invalid.  The recio warning number is 
  98. accessed through the rwarning function.
  99.  
  100. The rwarning function can return the following macro constants:
  101.  
  102.          0 - No warning.
  103.  R_WEMPSTR - empty data string.
  104.   R_WNOREG - unable to register exit function with atexit().
  105.   R_WWIDTH - data too wide for columnar output.
  106.  
  107.  
  108. 2.1 Define Callback Error Function
  109.  
  110. First define a callback error function to be used by the recio functions.
  111. You may give the function any name you wish.  In the sample function below,
  112. the name rerrfn is used.  The function takes one argument, a record pointer
  113. (REC *).  It returns nothing (void).  The function must first check for a
  114. valid record pointer using the risvalid function.  Other than that, you can
  115. customize it to do whatever you want.
  116.  
  117. The recio functions use a callback error function in order to give the
  118. most flexibility in handling errors.  This rerrfn function just sends
  119. information to stderr.  You may wish to send information to a printer,
  120. a file, a window, or a dialog box.  You might even want to give users
  121. the ability to examine errors and enter corrections.  If the error is
  122. corrected, you will want to call the rclearerr function before your
  123. callback error function returns.
  124.  
  125. When your callback error function is invoked, check rerror() or errno
  126. to determine the cause of the error.
  127.  
  128. Symbolic errno constants:
  129.  
  130. * EACCESS means that you don't have permission to access this file.  All
  131.   MSDOS files have read permission.
  132.  
  133. * EINVAL indicates an invalid argument to a function, usually a NULL record
  134.   pointer.  This resulted from a programming error.
  135.  
  136. * EMFILE means the program tried to open more files than the maximum allotted
  137.   by ROPEN_MAX or FOPEN_MAX.  If your program is interactive, the user can
  138.   close one or more open record streams.  Or you might decide that ROPEN_MAX
  139.   or FOPEN_MAX needs to be a larger value.
  140.  
  141. * ENOENT says that ropen() could not find the requested file to open.
  142.   Perhaps the name of the file was misspelled, or your program looked in
  143.   wrong directory.  If your program was trying to read a configuration file,
  144.   it could use internal default values when the configuration file does
  145.   not exist.
  146.  
  147. * ENOMEM indicates that the program ran out of heap space.  You may be able
  148.   to correct this if you are able to deallocate memory you no longer need.
  149.   For example, you could reduce the size of buffers when the size only
  150.   affects speed.  Such buffers need to be flushed first.  Buffers used by
  151.   the recio library do not fit this criteria.
  152.  
  153. Symbolic rerror() constants:
  154.  
  155. * R_EINVDAT says the data is invalid.  Invalid data is caused by an 
  156.   unrecognized character in the field.  For example, rgetui() doesn't 
  157.   expect to see a negative sign, so a negative number will be flagged as 
  158.   invalid data.
  159.  
  160. * R_EINVMOD indicates that you opened a file in read mode, then used an output 
  161.   function or opened a file in write or append mode, then used an input
  162.   function.
  163.  
  164. * R_EMISDAT says the data is missing.  Missing data means the field is empty.  
  165.   If you expect a number, you could substitute either zero or some unique 
  166.   number to indicate an empty field.
  167.  
  168. * R_ENOMEM indicates that the program ran out of heap space.  You may be able
  169.   to correct this if you are able to deallocate memory you no longer need.
  170.   For example, you could reduce the size of buffers when the size only
  171.   affects speed.  Such buffers need to be flushed first.  Buffers used by
  172.   the recio library do not fit this criteria.
  173.  
  174. * R_ENOPUT says the program was unable to write the data to output.  This 
  175.   could indicate that the disk is full.
  176.  
  177. * R_ERANGE tells you that the data is outside the range of the function.
  178.   For instance, suppose you used rgeti() to get an integer and the data
  179.   value is 32768.  If a 16-bit integer has an upper limit of 32767, the
  180.   value is too large.  If the data is wrong, you can have the error
  181.   function correct it.  If the data is right, you have to correct the 
  182.   data type in the program.
  183.  
  184. The main purpose of this sample callback error function is to show some of
  185. kinds of things you can do in a callback error function.  Note that when an
  186. error occurs, the column number indicator rcolno() has moved just beyond
  187. the error.  To make it clearer to the user where the error occurred, rerrfn()
  188. displays rcolno()-1, but not less than rbegcolno(), the column number for the 
  189. first column.  
  190.  
  191. A more detailed callback error function is given in the source code for the 
  192. test program TESTCHG.C.  The test program callback error function makes use 
  193. of the rfix functions to fix up bad data (primarily overflows and underflows) 
  194. and continue processing.  If appropriate for your application, you can use 
  195. these functions as well.  They have been compiled into the recio libraries 
  196. for your potential use.
  197.  
  198. /* define callback error function */
  199. void rerrfn(REC *rp)
  200. {
  201.     /* if rp is a valid record pointer */
  202.     if (risvalid(rp)) {
  203.  
  204.       /* if reof indicator set */
  205.       if (reof(rp)) {
  206.           fprintf(stderr, "ERROR reading %s -- "
  207.            "tried to read past end of file\n\n", rnames(rp));
  208.  
  209.       /* else rerror indicator set */
  210.       } else {
  211.  
  212.           /* determine cause of error */
  213.           switch (rerror(rp)) {
  214.  
  215.           /* input data errors */
  216.           case R_ERANGE:
  217.           case R_EINVDAT:
  218.           case R_EMISDAT:
  219.           /* output data errors */
  220.           case R_ENOPUT:
  221.  
  222.               /* print location of error */
  223.               fprintf(stderr, "DATA ERROR in FILE %s at LINE %ld,"
  224.                " FIELD %u, COLUMN %u -- %s\n", rnames(rp), rrecno(rp),
  225.                rfldno(rp), max(rcolno(rp)-1, rbegcolno(rp)), rerrstr(rp));
  226.               break;
  227.  
  228.           /* non-fatal errors */
  229.           case R_ENOREG:
  230.               fprintf(stderr, "WARNING -- %s\n", rerrstr(rp));
  231.               rclearerr();
  232.               break;
  233.  
  234.           /* fatal errors (R_EINVMOD, R_EINVAL, R_ENOMEM) */
  235.           default:
  236.             fprintf(errout, "FATAL ERROR reading FILE %s -- %s\n", 
  237.              rnames(rp), rerrstr(rp));
  238.             abort();
  239.             break;
  240.           }
  241.       }
  242.  
  243.     /* else invalid record pointer */
  244.     } else {
  245.         switch (errno) {
  246.  
  247.         /* non-fatal errors */
  248.         case EACCES:
  249.         case EMFILE:
  250.           fprintf(errout, "WARNING: %s\n", strerror(errno));
  251.           break;
  252.  
  253.         /* fatal errors (EINVAL, ENOMEM) */
  254.         default:
  255.           fprintf(errout, "FATAL ERROR: %s\n", strerror(errno));
  256.           abort();
  257.           break;
  258.         }
  259.     }
  260. }
  261.  
  262.  
  263. 2.2 Define Callback Warning Function
  264.  
  265. Next define a callback warning function.  You may give the function any name 
  266. you want.  In the sample function below, the name rwarnfn is used.  The 
  267. function takes one argument, a record pointer (REC *).  It returns nothing 
  268. (void).
  269.  
  270. The recio functions use a callback warning function in order to give the
  271. most flexibility in handling unusual conditions.  For example, the recio 
  272. library considers empty data strings to be legal but your application may 
  273. want to flag an empty data string as a data error.  You can do that by 
  274. checking for R_WEMPSTR warnings in your callback warning function.
  275.  
  276. When your callback warning function is invoked, check rwarning() to 
  277. determine the cause of the warning.
  278.  
  279. Symbolic warning constants:
  280.  
  281. * R_WEMPSTR says that an empty data string was input.  If you want to 
  282.   substitute another string, just use the rsetfldstr function to stuff the 
  283.   field buffer inside your callback warning function.
  284.  
  285. * R_WWIDTH indicates that on output, the data will not fit between the 
  286.   columns specified.  If the data is numeric, the recio output functions 
  287.   write asterisks to the output; if the data is a string, a truncated string 
  288.   is written.
  289.  
  290. * R_WNOREG means the program was unable to register the internal recio exit
  291.   function with the ANSI atexit() function.  The internal recio exit
  292.   function ensures that all open record streams are closed and all dynamic
  293.   memory allocated by the recio library is deallocated.
  294.  
  295. You can also use your callback warning function to keep track of the number 
  296. of warnings, then print a summary of any warnings just before you close a 
  297. record stream.  You will find an example in the test program TESTCHP.C.
  298.  
  299. void rwarnfn(REC *rp)
  300. {
  301.   if (risvalid(rp)) {
  302.     switch (rwarning(rp)) {
  303.     case R_WNOREG:   /* atexit() full */
  304.       fprintf (errout, "WARNING %s\n", rwarnstr(rp));
  305.       break;
  306.     case R_WEMPSTR:  /* empty data string */
  307.       fprintf(errout, "WARNING reading %s at record %lu and field %u -- %s\n", 
  308.        rnames(rp), rrecno(rp), rfldno(rp), rwarnstr(rp));
  309.       break;
  310.     }
  311.   }
  312. }
  313.  
  314. 2.3 Register Callback Error and Warning Functions
  315.  
  316. Once you have written your callback error and warning functions, you must let 
  317. the other recio functions know that they exist.  You use the rseterrfn and 
  318. rsetwarnfn functions to register your callback functions.
  319.  
  320.     /* register callback error and warning functions */
  321.     rseterrfn(rerrfn);
  322.     rsetwarnfn(rwarnfn);
  323.  
  324.  
  325.  
  326. 3.0 OPEN FILE
  327.  
  328.  
  329. 3.1 Open File and Get Record Pointer
  330.  
  331. Use the ropen function to open the file you want to read, write, or append.  
  332. Store the record pointer returned by the ropen function.  Do not open recin, 
  333. recout, recerr, or recprn (MSDOS printer).  They are always open, so they do 
  334. not need to be opened or closed.
  335.  
  336.     REC *rp = ropen("FILENAME.DAT", "r");
  337.  
  338.  
  339. 3.2 Check Record Pointer
  340.  
  341. Following the ropen function, you need to check to see if the file was
  342. opened correctly.  If ropen returned a NULL pointer, then the file was not
  343. opened.
  344.  
  345. Errors other than ENOENT are reported to your callback error function.
  346. ENOENT is not reported since you may want to use default values if the
  347. data file is not available.
  348.  
  349.     /* if ropen() failed */
  350.     if (!rp) {
  351.         /* if it failed because file does not exist */
  352.         if (errno==ENOENT) {
  353.             /* action to take when file does not exist */
  354.             ...
  355.         }
  356.     /* else ropen() succeeded */
  357.     } else {
  358.         /* set up stream (see sections 3.3 - 3.6) */
  359.         ...
  360.         /* read or write file (see sections 4 and 5) */
  361.         ...
  362.         /* close file (see section 6) */
  363.         rclose(rp);
  364.     }
  365.  
  366.  
  367. 3.3 Set Field and Text Delimiters
  368.  
  369. The space character is the default value for both the field and text 
  370. delimiters.  The space character matches any white space.  If you need to 
  371. use something else, you need to explicitly set the values.  Application 
  372. maintenance will be easier if you always set the values.
  373.  
  374.     rsetfldch(rp, ',');  /* set field delimiter character */
  375.     rsettxtch(rp, '"');  /* set text delimiter character */
  376.  
  377.  
  378. 3.4 Set Field and Record Buffer Sizes
  379.  
  380. Setting the field and record buffer sizes is optional.  Buffers will be
  381. automatically reallocated as necessary.  However if you set the field and 
  382. record sizes in advance to the maximum value needed, you can reduce memory 
  383. fragmentation.  The field and record buffers are not used for output.
  384.  
  385.     rsetfldsiz(rp, 41);  /* set size of field buffer */
  386.     rsetrecsiz(rp, 133); /* set size of record buffer */
  387.  
  388.  
  389. 3.5 Set Context Number
  390.  
  391. If your application opens record streams with more than one data format, you 
  392. will want to set a context number.  You use the context number so that your 
  393. callback error function can determine (using the rcxtno function) which data 
  394. format it is dealing with.  Each context number must be a positive integer; 
  395. zero and negative numbers are reserved.  Predefined context symbolic 
  396. constants are RECIN, RECOUT, RECERR, and (for MSDOS) RECPRN.
  397.  
  398. #define SOILS_DB      1
  399. #define BUILDINGS_DB  2
  400.  
  401.      rsetcxtno(rp, SOILS_DB); /* set context number */
  402.  
  403.  
  404. 3.6 Set Beginning Column Number
  405.  
  406. The first column number in the record buffer defaults to zero.  If you prefer 
  407. column numbering to start at one, use the rsetbegcolno function.  It is mainly 
  408. useful if using column delimited data.  If a number takes up the first ten 
  409. columns of the record, the column numbering will be 0 to 9 if rsetbegcolno() 
  410. is set to 0, or 1 to 10 is rsetbegcolno() is set to 1.
  411.  
  412.      rsetbegcolno(rp, 1); /* first column is column 1 */
  413.  
  414.  
  415.  
  416. 4.0 RECORD FUNCTIONS
  417.  
  418. 4.1 The rgetrec Function
  419.  
  420. If all the records in a data file have the same format, you will want to 
  421. loop through all the records until the end of file is reached.  If each
  422. record has a different format, you must call the rgetrec function each
  423. time you want to get the next record.  Calling rgetrec() is optional for
  424. the first record.
  425.  
  426.     /* read all records in file */
  427.     while (rgetrec(rp)) {
  428.         /* Section 5 field functions go here ... */
  429.     }
  430.  
  431.  
  432. 4.2 The rputrec Function
  433.  
  434. After you write all the fields in one record, use the rputrec function 
  435. to put the end-of-record newline character to the output and to reset the 
  436. internal recio library variables for the next record.
  437.  
  438.     /* write end-of-record */
  439.     rputrec(rp);
  440.  
  441.  
  442. 4.3 The rrecs Macro
  443.  
  444. To get a pointer to the start of the record buffer, use the rrecs macro.
  445.  
  446.     /* echo record contents to stdout */
  447.     printf("%s\n", rrecs(rp));
  448.  
  449.  
  450. 4.4 The rrecno Macro
  451.  
  452. To get the record number, use the rrecno macro.
  453.  
  454.     /* echo record number and record contents to stdout */
  455.     printf("%ld: %s\n", rrecno(rp), rrecs(rp));
  456.  
  457.  
  458.  
  459. 5.0 GET AND PUT FIELD DATA
  460.  
  461. 5.1 Field functions
  462.  
  463. There are 48 functions that can be used to read or write data.  A mnemonic 
  464. system makes it easy to construct the name of any function you want.  All you 
  465. need to remember is that there are four prefixes, two bodies, and eight 
  466. suffixes, and that the rb and rcb prefixes are used only with the i, l, ui, 
  467. and ul suffixes.  
  468.  
  469. If the prefix contains the letter 'c', it is a column delimited field function.  
  470. If the prefix contains the letter 'b', it is a field function that reads or 
  471. writes an integral number in a specified base (radix).  The eight suffixes 
  472. indicate the eight data types: character, double, float, integer, long, 
  473. string, unsigned integer, and unsigned long.
  474.  
  475.     Prefix   Body   Suffix      Prefix   Body   Suffix
  476.     ------   ----   ------      ------   ----   ------
  477.       r       get      c          rb      get      i
  478.       rc      put      d          rcb     put      l
  479.                        f                          ui
  480.                        i                          ul
  481.                        l
  482.                        s
  483.                       ui
  484.                       ul
  485.  
  486.  
  487. 5.2 The rskipfld Macro
  488.  
  489. If your application does not need to read the data in a field, you can skip 
  490. over the field by using the rskipfld macro.
  491.  
  492.     /* skip over a field */
  493.     if (rskipfld(rp) != 1) printf("Unable to skip field.\n");
  494.  
  495.  
  496. 5.3 The rskipnfld Function
  497.  
  498. If your application does not need to read the data in several adjacent 
  499. fields, you can skip over the fields by using the rskipnfld function.
  500.  
  501.     /* skip over three fields */
  502.     if (rskipnfld(rp, 3) != 3) printf("Unable to skip 3 fields.\n");
  503.  
  504.  
  505. 5.4 The reof Macro
  506.  
  507. Use the reof macro to determine when the record stream has reached the 
  508. end of file.
  509.  
  510.     /* if error or end of file reached */
  511.     while (rgetrec(rp)) {
  512.     ...
  513.     }
  514.     /* if end of file */
  515.     if (reof(rp)) {
  516.        ...
  517.     /* else error */
  518.     } else {
  519.        ...
  520.     }
  521.     
  522.  
  523. 5.5 The rerror Function
  524.  
  525. Use the rerror function to determine if an error has occurred on a record 
  526. stream.  You can access a text string for the error using the rerrstr
  527. function.
  528.  
  529.     if (rerror(rp)) 
  530.         printf("ERROR reading %s - %s\n", 
  531.          rnames(rp), rerrstr(rp));
  532.     rclose(rp);
  533.  
  534. It is a good practice to check for any errors just before closing 
  535. a record stream.  If the error indicator is clear, you have additional 
  536. confidence that the stream was processed correctly.
  537.  
  538.  
  539. 5.6 The rseterr Function
  540.  
  541. If you write wrapper functions or other functions that interact with 
  542. recio functions, your code will need to handle errors.  If can use 
  543. the rseterr function to set the error number and to call the record 
  544. stream callback error function.
  545.  
  546. /* get integer and validate range */
  547. int rrgeti(REC *rp, int min, int max) {
  548.     int result;
  549.     
  550.     result = rgeti(rp);
  551.     if (result < min || result > max) {
  552.         rseterr(rp, R_ERANGE);
  553.     }
  554.     return result;
  555. }
  556.  
  557.  
  558. 5.7 The rwarning Function
  559.  
  560. Use the rwarning macro to determine if a warning has occurred on a record 
  561. stream.
  562.  
  563.     if (rwarning(rp)) 
  564.         printf("ERROR %s - %s\n", rnames(rp), rwarnstr(rp));
  565.  
  566. It is good practice to check for any warnings just before closing an output 
  567. record stream.
  568.  
  569.  
  570. 5.8 The rsetwarn Function
  571.  
  572. If you write wrapper functions or other functions that interact with recio 
  573. functions, you may need to provide warnings.  The rsetwarn function sets the 
  574. warning number and calls the record stream callback warning function.
  575.  
  576.     rsetwarn(rp, R_WWIDTH);
  577.  
  578.  
  579.  
  580. 6.0 CLOSE FILE
  581.  
  582. 6.1 Close File
  583.  
  584. When finished reading or writing a data file, close it.  Do not close recin, 
  585. recout, recerr, or recprn as they are always open.
  586.  
  587.     /* close record file */
  588.     rclose(rp);
  589.  
  590.  
  591. 6.2 Close All Files
  592.  
  593. Rather than closing record files one at a time, one can close all open 
  594. record files at once using the rcloseall function.
  595.  
  596.     /* all done */
  597.     rcloseall();
  598.  
  599.  
  600.  
  601. 7.0 REFERENCES
  602.  
  603. 1. ANSI X3.159-1989, "American National Standard for Information Systems -
  604.    Programming Language - C," American National Standards Institute, 
  605.    11 West 42nd Street, New York, NY 10036, 1990.
  606.  
  607.  
  608. 8.0 INDEX
  609.  
  610. errno macro ............ 2.0, 2.1, 3.2
  611. rbegcolno macro ........ 2.1
  612. rclearerr function ..... 2.1
  613. rclose function ........ 6.1
  614. rcloseall function ..... 6.2
  615. rcolno macro ........... 2.1
  616. rcxtno macro ........... 3.5
  617. recin expression ....... 3.1, 6.1
  618. reof macro ............. 2.1, 5.4
  619. rerror function ........ 2.1, 5.5
  620. rerrstr function ....... 2.1, 5.5
  621. rfix functions ......... 2.1
  622. rflds macro ............ 2.1
  623. rfldno macro ........... 2.1
  624. rbget functions ........ 5.1
  625. rbput functions ........ 5.1
  626. rcbget functions ....... 5.1
  627. rcbput functions ....... 5.1
  628. rcget functions ........ 5.1
  629. rcput functions ........ 5.1
  630. rget functions ......... 5.1
  631. rgetrec function ....... 4.1
  632. risvalid function ...... 2.1
  633. rnames macro ........... 2.1
  634. ropen function  ........ 3.1
  635. rput functions ......... 5.1
  636. rrecs macro ............ 2.1, 4.3
  637. rrecno macro ........... 2.1, 4.4
  638. rsetbegcolno function .. 3.6
  639. rsetcxtno function ..... 3.5
  640. rseterr function ....... 5.6
  641. rseterrfn function ..... 2.3
  642. rsetfldch function ..... 3.3
  643. rsetfldsiz function .... 3.4
  644. rsetfldstr function .... 2.1
  645. rsetrecsiz function .... 3.4
  646. rsettxtch function ..... 3.3
  647. rsetwarn function ...... 5.8
  648. rsetwarnfn function .... 2.3
  649. rskipfld macro  ........ 5.2
  650. rskipnfld function ..... 5.3
  651. rwarning function ...... 2.2, 5.7
  652. rwarnstr function ...... 2.2, 5.7
  653.